package com.example.demo.cart.controller;

import com.example.demo.cart.po.User;
import com.example.demo.cart.service.CartService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author yj
 * @date 2019.9.27
 */
@RestController
@RequestMapping("cart")
public class CartController {

    @Autowired
    private CartService cartService;

    @RequestMapping("test")
    public String Test(){
        return "666";
    }
    @RequestMapping("query")
    public List<User> getUserList(){
        return cartService.getUserList();
    }
}
